

#top makefile

# This is a basic Makefile for setting the general configuration
include Makeheader.mk



all:   CHECK_DIR $(SUBDIRS)

CHECK_DIR:
	@mkdir -p $(BIN_DIR)
	
$(SUBDIRS):ECHO 
	@make -C $@ 

#显示所有的目录
ECHO:
	@echo $(SUBDIRS)
	@echo begin compile


.PHONY: clean

clean:
	rm -f *.o *.a  
	for i in $(SUBDIRS) ; do make clean -C $$i; done
	rm  $(TARGET)  	
	rm -R ./bin/$(TARGET)  


#clean:
#	rm -f *.o *.a  
#	rm  $(TARGET)  	
##make 发现错误会立刻停止不再往前执行	
#	rm -R ./bin/$(TARGET)  
#	for i in $(SUBDIRS) ; do make clean -C $$i; done


